home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1993 July / InfoMagic USENET CD-ROM July 1993.ISO / sources / misc / volume19 / dmake / part36 < prev    next >
Encoding:
Text File  |  1991-05-13  |  40.4 KB  |  1,231 lines

  1. Newsgroups: comp.sources.misc
  2. From: Dennis Vadura <dvadura@watdragon.waterloo.edu>
  3. Subject:  v19i057:  dmake - dmake version 3.7, Part36/37
  4. Message-ID: <1991May13.145453.9976@sparky.IMD.Sterling.COM>
  5. X-Md4-Signature: d8a8e4ce3abb1bec64108247235d9b17
  6. Date: Mon, 13 May 1991 14:54:53 GMT
  7. Approved: kent@sparky.imd.sterling.com
  8.  
  9. Submitted-by: Dennis Vadura <dvadura@watdragon.waterloo.edu>
  10. Posting-number: Volume 19, Issue 57
  11. Archive-name: dmake/part36
  12. Supersedes: dmake-3.6: Volume 15, Issue 52-77
  13.  
  14. ---- Cut Here and feed the following to sh ----
  15. #!/bin/sh
  16. # this is dmake.shar.36 (part 36 of a multipart archive)
  17. # do not concatenate these parts, unpack them in order with /bin/sh
  18. # file dmake/unix/sysvr3/config.mk continued
  19. #
  20. if test ! -r _shar_seq_.tmp; then
  21.     echo 'Please unpack part 1 first!'
  22.     exit 1
  23. fi
  24. (read Scheck
  25.  if test "$Scheck" != 36; then
  26.     echo Please unpack part "$Scheck" next!
  27.     exit 1
  28.  else
  29.     exit 0
  30.  fi
  31. ) < _shar_seq_.tmp || exit 1
  32. if test -f _shar_wnt_.tmp; then
  33. sed 's/^X//' << 'SHAR_EOF' >> 'dmake/unix/sysvr3/config.mk' &&
  34. X   .INCLUDE .IGNORE : $(osrdir)$(DIRSEPSTR)$(OSENVIRONMENT)$(DIRSEPSTR)config.mk
  35. .END
  36. SHAR_EOF
  37. chmod 0640 dmake/unix/sysvr3/config.mk ||
  38. echo 'restore of dmake/unix/sysvr3/config.mk failed'
  39. Wc_c="`wc -c < 'dmake/unix/sysvr3/config.mk'`"
  40. test 750 -eq "$Wc_c" ||
  41.     echo 'dmake/unix/sysvr3/config.mk: original size 750, current size' "$Wc_c"
  42. rm -f _shar_wnt_.tmp
  43. fi
  44. # ============= dmake/unix/sysvr3/make.sh ==============
  45. if test -f 'dmake/unix/sysvr3/make.sh' -a X"$1" != X"-c"; then
  46.     echo 'x - skipping dmake/unix/sysvr3/make.sh (File already exists)'
  47.     rm -f _shar_wnt_.tmp
  48. else
  49. > _shar_wnt_.tmp
  50. sed 's/^X//' << 'SHAR_EOF' > 'dmake/unix/sysvr3/make.sh' &&
  51. mkdir objects
  52. cc -c -I. -Iunix -Iunix/sysvr3 -O infer.c
  53. mv infer.o objects
  54. cc -c -I. -Iunix -Iunix/sysvr3 -O make.c
  55. mv make.o objects
  56. cc -c -I. -Iunix -Iunix/sysvr3 -O stat.c
  57. mv stat.o objects
  58. cc -c -I. -Iunix -Iunix/sysvr3 -O expand.c
  59. mv expand.o objects
  60. cc -c -I. -Iunix -Iunix/sysvr3 -O dmstring.c
  61. mv dmstring.o objects
  62. cc -c -I. -Iunix -Iunix/sysvr3 -O hash.c
  63. mv hash.o objects
  64. cc -c -I. -Iunix -Iunix/sysvr3 -O dag.c
  65. mv dag.o objects
  66. cc -c -I. -Iunix -Iunix/sysvr3 -O dmake.c
  67. mv dmake.o objects
  68. cc -c -I. -Iunix -Iunix/sysvr3 -O path.c
  69. mv path.o objects
  70. cc -c -I. -Iunix -Iunix/sysvr3 -O imacs.c
  71. mv imacs.o objects
  72. cc -c -I. -Iunix -Iunix/sysvr3 -O sysintf.c
  73. mv sysintf.o objects
  74. cc -c -I. -Iunix -Iunix/sysvr3 -O parse.c
  75. mv parse.o objects
  76. cc -c -I. -Iunix -Iunix/sysvr3 -O getinp.c
  77. mv getinp.o objects
  78. cc -c -I. -Iunix -Iunix/sysvr3 -O quit.c
  79. mv quit.o objects
  80. cc -c -I. -Iunix -Iunix/sysvr3 -O state.c
  81. mv state.o objects
  82. cc -c -I. -Iunix -Iunix/sysvr3 -O basename.c
  83. mv basename.o objects
  84. cc -c -I. -Iunix -Iunix/sysvr3 -O dmdump.c
  85. mv dmdump.o objects
  86. cc -c -I. -Iunix -Iunix/sysvr3 -O macparse.c
  87. mv macparse.o objects
  88. cc -c -I. -Iunix -Iunix/sysvr3 -O rulparse.c
  89. mv rulparse.o objects
  90. cc -c -I. -Iunix -Iunix/sysvr3 -O percent.c
  91. mv percent.o objects
  92. cc -c -I. -Iunix -Iunix/sysvr3 -O function.c
  93. mv function.o objects
  94. cc -c -I. -Iunix -Iunix/sysvr3 -O unix/arlib.c
  95. mv arlib.o objects
  96. cc -c -I. -Iunix -Iunix/sysvr3 -O unix/dirbrk.c
  97. mv dirbrk.o objects
  98. cc -c -I. -Iunix -Iunix/sysvr3 -O unix/rmprq.c
  99. mv rmprq.o objects
  100. cc -c -I. -Iunix -Iunix/sysvr3 -O unix/ruletab.c
  101. mv ruletab.o objects
  102. cc -c -I. -Iunix -Iunix/sysvr3 -O unix/runargv.c
  103. mv runargv.o objects
  104. cc  -o dmake  objects/infer.o objects/make.o objects/stat.o objects/expand.o objects/dmstring.o objects/hash.o objects/dag.o objects/dmake.o objects/path.o objects/imacs.o objects/sysintf.o objects/parse.o objects/getinp.o objects/quit.o objects/state.o objects/basename.o objects/dmdump.o objects/macparse.o objects/rulparse.o objects/percent.o objects/function.o objects/arlib.o objects/dirbrk.o objects/rmprq.o objects/ruletab.o objects/runargv.o 
  105. cp unix/sysvr3/startup.mk startup.mk
  106. SHAR_EOF
  107. chmod 0640 dmake/unix/sysvr3/make.sh ||
  108. echo 'restore of dmake/unix/sysvr3/make.sh failed'
  109. Wc_c="`wc -c < 'dmake/unix/sysvr3/make.sh'`"
  110. test 2153 -eq "$Wc_c" ||
  111.     echo 'dmake/unix/sysvr3/make.sh: original size 2153, current size' "$Wc_c"
  112. rm -f _shar_wnt_.tmp
  113. fi
  114. # ============= dmake/unix/sysvr3/public.h ==============
  115. if test -f 'dmake/unix/sysvr3/public.h' -a X"$1" != X"-c"; then
  116.     echo 'x - skipping dmake/unix/sysvr3/public.h (File already exists)'
  117.     rm -f _shar_wnt_.tmp
  118. else
  119. > _shar_wnt_.tmp
  120. sed 's/^X//' << 'SHAR_EOF' > 'dmake/unix/sysvr3/public.h' &&
  121. /* RCS      -- $Header: /u2/dvadura/src/generic/dmake/src/unix/sysvr3/RCS/public.h,v 1.1 91/05/06 15:28:22 dvadura Exp Locker: dvadura $
  122. -- WARNING  -- This file is AUTOMATICALLY GENERATED DO NOT EDIT IT
  123. --
  124. -- SYNOPSIS -- Local functions exported to be visible by others.
  125. --
  126. -- DESCRIPTION
  127. --      This file is generated by 'genpub'.  Function declarations
  128. --      that appear in this file are extracted by 'genpub' from
  129. --      source files.  Any function in the source file whose definition
  130. --      appears like:
  131. --
  132. --          PUBLIC return_type
  133. --          function( arg_list );
  134. --          type_expr1 arg1;
  135. --          ...
  136. --
  137. --      has its definition extracted and a line of the form:
  138. --
  139. --          return_type function ANSI((type_expr1,type_expr2,...));
  140. --
  141. --      entered into the output file.
  142. --
  143. -- AUTHOR
  144. --      Dennis Vadura, dvadura@watdragon.uwaterloo.ca
  145. --      CS DEPT, University of Waterloo, Waterloo, Ont., Canada
  146. --
  147. -- COPYRIGHT
  148. --      Copyright (c) 1990 by Dennis Vadura.  All rights reserved.
  149. -- 
  150. --      This program is free software; you can redistribute it and/or
  151. --      modify it under the terms of the GNU General Public License
  152. --      (version 1), as published by the Free Software Foundation, and
  153. --      found in the file 'LICENSE' included with this distribution.
  154. -- 
  155. --      This program is distributed in the hope that it will be useful,
  156. --      but WITHOUT ANY WARRANTY; without even the implied warrant of
  157. --      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  158. --      GNU General Public License for more details.
  159. -- 
  160. --      You should have received a copy of the GNU General Public License
  161. --      along with this program;  if not, write to the Free Software
  162. --      Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  163. --
  164. -- LOG
  165. --     $Log:    public.h,v $
  166. X * Revision 1.1  91/05/06  15:28:22  dvadura
  167. X * dmake Release Version 3.7
  168. X * 
  169. */
  170. X
  171. #ifndef _DMAKE_PUBLIC_h
  172. #define _DMAKE_PUBLIC_h
  173. X
  174. void Infer_recipe ANSI((CELLPTR, CELLPTR));
  175. int Make_targets ANSI(());
  176. int Exec_commands ANSI((CELLPTR));
  177. void Pop_dir ANSI((int));
  178. void Append_line ANSI((char *, int, FILE *, char *, int, int));
  179. void Stat_target ANSI((CELLPTR, int));
  180. char * Expand ANSI((char *));
  181. char * Apply_edit ANSI((char *, char *, char *, int, int));
  182. void Map_esc ANSI((char *));
  183. char* Apply_modifiers ANSI((int, char *));
  184. char* Tokenize ANSI((char *, char *));
  185. char * _strjoin ANSI((char *, char *, int, int));
  186. char * _stradd ANSI((char *, char *, int));
  187. char * _strapp ANSI((char *, char *));
  188. char * _strdup ANSI((char *));
  189. char * _strpbrk ANSI((char *, char *));
  190. char * _strspn ANSI((char *, char *));
  191. char * _strstr ANSI((char *, char *));
  192. char * _substr ANSI((char *, char *));
  193. uint16 Hash ANSI((char *, uint32 *));
  194. HASHPTR Get_name ANSI((char *, HASHPTR *, int));
  195. HASHPTR Search_table ANSI((HASHPTR *, char *, uint16 *, uint32 *));
  196. HASHPTR Def_macro ANSI((char *, char *, int));
  197. CELLPTR Def_cell ANSI((char *));
  198. LINKPTR Add_prerequisite ANSI((CELLPTR, CELLPTR, int, int));
  199. void Clear_prerequisites ANSI((CELLPTR));
  200. int Test_circle ANSI((CELLPTR, int));
  201. STRINGPTR Def_recipe ANSI((char *, STRINGPTR, int, int));
  202. t_attr Rcp_attribute ANSI((char *));
  203. int main ANSI((int, char **));
  204. FILE * Openfile ANSI((char *, int, int));
  205. FILE * Closefile ANSI(());
  206. FILE * Search_file ANSI((char *, char **));
  207. char * Filename ANSI(());
  208. void No_ram ANSI(());
  209. int Usage ANSI((int));
  210. int Version ANSI(());
  211. char * Get_suffix ANSI((char *));
  212. char * Build_path ANSI((char *, char *));
  213. void Make_rules ANSI(());
  214. void Create_macro_vars ANSI(());
  215. time_t Do_stat ANSI((char *, char *, char **));
  216. int Do_touch ANSI((char *, char *, char **));
  217. void Void_lib_cache ANSI((char *, char *));
  218. time_t Do_time ANSI(());
  219. int Do_cmnd ANSI((char *, int, int, CELLPTR, int, int, int));
  220. char ** Pack_argv ANSI((int, int, char *));
  221. char * Read_env_string ANSI((char *));
  222. int Write_env_string ANSI((char *, char *));
  223. void ReadEnvironment ANSI(());
  224. void Catch_signals ANSI((void (*)()));
  225. void Clear_signals ANSI(());
  226. void Prolog ANSI((int, char* []));
  227. void Epilog ANSI((int));
  228. char * Get_current_dir ANSI(());
  229. int Set_dir ANSI((char*));
  230. char Get_switch_char ANSI(());
  231. FILE* Get_temp ANSI((char **, char *, int));
  232. FILE * Start_temp ANSI((char *, CELLPTR, char **));
  233. void Open_temp_error ANSI((char *, char *));
  234. void Link_temp ANSI((CELLPTR, FILE *, char *));
  235. void Close_temp ANSI((CELLPTR, FILE *));
  236. void Unlink_temp_files ANSI((CELLPTR));
  237. void Handle_result ANSI((int, int, int, CELLPTR));
  238. void Update_time_stamp ANSI((CELLPTR));
  239. void Parse ANSI((FILE *));
  240. int Get_line ANSI((char *, FILE *));
  241. char * Do_comment ANSI((char *, char **, int));
  242. char * Get_token ANSI((TKSTRPTR, char *, int));
  243. void Quit ANSI(());
  244. void Read_state ANSI(());
  245. void Write_state ANSI(());
  246. int Check_state ANSI((CELLPTR, STRINGPTR *, int));
  247. char* basename ANSI((char *));
  248. void Dump ANSI(());
  249. void Dump_recipe ANSI((STRINGPTR));
  250. int Parse_macro ANSI((char *, int));
  251. int Macro_op ANSI((char *));
  252. int Parse_rule_def ANSI((int *));
  253. int Rule_op ANSI((char *));
  254. void Add_recipe_to_list ANSI((char *, int, int));
  255. void Bind_rules_to_targets ANSI((int));
  256. int Set_group_attributes ANSI((char *));
  257. DFALINKPTR Match_dfa ANSI((char *));
  258. void Check_circle_dfa ANSI(());
  259. void Add_nfa ANSI((char *));
  260. char * Exec_function ANSI((char *));
  261. time_t seek_arch ANSI((char *, char *));
  262. int If_root_path ANSI((char *));
  263. void Remove_prq ANSI((CELLPTR));
  264. int runargv ANSI((CELLPTR, int, int, int, int, char *));
  265. int Wait_for_child ANSI((int, int));
  266. void Clean_up_processes ANSI(());
  267. X
  268. #endif
  269. SHAR_EOF
  270. chmod 0640 dmake/unix/sysvr3/public.h ||
  271. echo 'restore of dmake/unix/sysvr3/public.h failed'
  272. Wc_c="`wc -c < 'dmake/unix/sysvr3/public.h'`"
  273. test 5522 -eq "$Wc_c" ||
  274.     echo 'dmake/unix/sysvr3/public.h: original size 5522, current size' "$Wc_c"
  275. rm -f _shar_wnt_.tmp
  276. fi
  277. # ============= dmake/unix/sysvr3/startup.mk ==============
  278. if test -f 'dmake/unix/sysvr3/startup.mk' -a X"$1" != X"-c"; then
  279.     echo 'x - skipping dmake/unix/sysvr3/startup.mk (File already exists)'
  280.     rm -f _shar_wnt_.tmp
  281. else
  282. > _shar_wnt_.tmp
  283. sed 's/^X//' << 'SHAR_EOF' > 'dmake/unix/sysvr3/startup.mk' &&
  284. # Generic UNIX DMAKE startup file.  Customize to suit your needs.
  285. # Should work for both SYSV, and BSD 4.3
  286. # See the documentation for a description of internally defined macros.
  287. #
  288. # Disable warnings for macros redefined here that were given
  289. # on the command line.
  290. __.SILENT := $(.SILENT)
  291. .SILENT   := yes
  292. X
  293. # Configuration parameters for DMAKE startup.mk file
  294. # Set these to NON-NULL if you wish to turn the parameter on.
  295. _HAVE_RCS    := yes        # yes => RCS  is installed.
  296. _HAVE_SCCS    := yes        # yes => SCCS is installed.
  297. X
  298. # Applicable suffix definitions
  299. A := .a        # Libraries
  300. E :=        # Executables
  301. F := .f        # Fortran
  302. O := .o        # Objects
  303. P := .p        # Pascal
  304. S := .s        # Assembler sources
  305. V := ,v        # RCS suffix
  306. X
  307. # Recipe execution configurations
  308. SHELL        := /bin/sh
  309. SHELLFLAGS    := -ce
  310. GROUPSHELL    := $(SHELL)
  311. GROUPFLAGS    := 
  312. SHELLMETAS    := |();&<>?*][$$:\\#`'"
  313. GROUPSUFFIX    :=
  314. DIVFILE         = $(TMPFILE)
  315. X
  316. # Standard C-language command names and flags
  317. X   CPP       := /lib/cpp        # C-preprocessor
  318. X   CC      := cc        # C-compiler and flags
  319. X   CFLAGS  +=
  320. X
  321. X   AS      := as        # Assembler and flags
  322. X   ASFLAGS += 
  323. X
  324. X   LD       = $(CC)        # Loader and flags
  325. X   LDFLAGS +=
  326. X   LDLIBS   =
  327. X
  328. # Definition of $(MAKE) macro for recursive makes.
  329. X   MAKE = $(MAKECMD) $(MFLAGS)
  330. X
  331. # Definition of Print command for this system.
  332. X   PRINT = lpr
  333. X
  334. # Language and Parser generation Tools and their flags
  335. X   YACC      := yacc        # standard yacc
  336. X   YFLAGS +=
  337. X   YTAB      := y.tab        # yacc output files name stem.
  338. X
  339. X   LEX      := lex        # standard lex
  340. X   LFLAGS +=
  341. X   LEXYY  := lex.yy        # lex output file
  342. X
  343. # Other Compilers, Tools and their flags
  344. X   PC    := pc            # pascal compiler
  345. X   RC    := f77            # ratfor compiler
  346. X   FC    := f77            # fortran compiler
  347. X
  348. X   CO       := co        # check out for RCS
  349. X   COFLAGS += -q
  350. X
  351. X   AR     := ar            # archiver
  352. X   ARFLAGS+= ruv
  353. X
  354. X   RM       := /bin/rm        # remove a file command
  355. X   RMFLAGS +=
  356. X
  357. # Implicit generation rules for making inferences.
  358. # We don't provide .yr or .ye rules here.  They're obsolete.
  359. # Rules for making *$O
  360. X   %$O : %.c ; $(CC) $(CFLAGS) -c $<
  361. X   %$O : %$P ; $(PC) $(PFLAGS) -c $<
  362. X   %$O : %$S ; $(AS) $(ASFLAGS) $<
  363. X   %$O : %.cl ; class -c $<
  364. X   %$O : %.e %.r %.F %$F
  365. X    $(FC) $(RFLAGS) $(EFLAGS) $(FFLAGS) -c $<
  366. X
  367. # Executables
  368. X   %$E : %$O ; $(LD) $(LDFLAGS) -o $@ $< $(LDLIBES)
  369. X
  370. # lex and yacc rules
  371. X   %.c : %.y ; $(YACC)  $(YFLAGS) $<; mv $(YTAB).c $@
  372. X   %.c : %.l ; $(LEX)   $(LFLAGS) $<; mv $(LEXYY).c $@
  373. X
  374. # This rule tells how to make *.out from it's immediate list of prerequisites
  375. # UNIX only.
  376. X   %.out :; $(LD) $(LDFLAGS) -o $@ $^ $(LDLIBS)
  377. X
  378. # RCS support
  379. .IF $(_HAVE_RCS)
  380. X   % : %$V $$(@:d)RCS/$$(@:f)$V;- $(CO) $(COFLAGS) $@
  381. X   .NOINFER : %$V $$(@:d)RCS/$$(@:f)$V
  382. .END
  383. X
  384. # SCCS support
  385. .IF $(_HAVE_SCCS)
  386. X   % : s.% ; get $@
  387. X   .NOINFER : s.%
  388. .END
  389. X
  390. # Recipe to make archive files.
  391. %$A :
  392. [
  393. X   $(AR) $(ARFLAGS) $@ $?
  394. X   $(RM) $(RMFLAGS) $?
  395. X   ranlib $@
  396. ]
  397. X
  398. # DMAKE uses this recipe to remove intermediate targets
  399. .REMOVE :; $(RM) -f $<
  400. X
  401. # AUGMAKE extensions for SYSV compatibility
  402. @B = $(@:b)
  403. @D = $(@:d)
  404. @F = $(@:f)
  405. *B = $(*:b)
  406. *D = $(*:d)
  407. *F = $(*:f)
  408. <B = $(<:b)
  409. <D = $(<:d)
  410. <F = $(<:f)
  411. ?B = $(?:b)
  412. ?F = $(?:f)
  413. ?D = $(?:d)
  414. X
  415. # Turn warnings back to previous setting.
  416. .SILENT := $(__.SILENT)
  417. X
  418. # Local startup file if any
  419. .INCLUDE .IGNORE: "_startup.mk"
  420. SHAR_EOF
  421. chmod 0640 dmake/unix/sysvr3/startup.mk ||
  422. echo 'restore of dmake/unix/sysvr3/startup.mk failed'
  423. Wc_c="`wc -c < 'dmake/unix/sysvr3/startup.mk'`"
  424. test 3221 -eq "$Wc_c" ||
  425.     echo 'dmake/unix/sysvr3/startup.mk: original size 3221, current size' "$Wc_c"
  426. rm -f _shar_wnt_.tmp
  427. fi
  428. # ============= dmake/unix/sysvr3/stdarg.h ==============
  429. if test -f 'dmake/unix/sysvr3/stdarg.h' -a X"$1" != X"-c"; then
  430.     echo 'x - skipping dmake/unix/sysvr3/stdarg.h (File already exists)'
  431.     rm -f _shar_wnt_.tmp
  432. else
  433. > _shar_wnt_.tmp
  434. sed 's/^X//' << 'SHAR_EOF' > 'dmake/unix/sysvr3/stdarg.h' &&
  435. /*
  436. X * stdarg.h
  437. X *
  438. X * defines ANSI style macros for accessing arguments of a function which takes
  439. X * a variable number of arguments
  440. X *
  441. X */
  442. X
  443. #if !defined(__STDARG_H__)
  444. #define __STDARG_H__
  445. X
  446. #if !defined(_VA_LIST_) && !defined(_VA_LIST)
  447. #define _VA_LIST_
  448. #define _VA_LIST
  449. typedef char *va_list;
  450. #endif
  451. X
  452. #define va_dcl int va_alist
  453. #define va_start(ap,v)  ap = (va_list)&va_alist
  454. #define va_arg(ap,t)    ((t*)(ap += sizeof(t)))[-1]
  455. #define va_end(ap)      ap = NULL
  456. #endif
  457. SHAR_EOF
  458. chmod 0640 dmake/unix/sysvr3/stdarg.h ||
  459. echo 'restore of dmake/unix/sysvr3/stdarg.h failed'
  460. Wc_c="`wc -c < 'dmake/unix/sysvr3/stdarg.h'`"
  461. test 469 -eq "$Wc_c" ||
  462.     echo 'dmake/unix/sysvr3/stdarg.h: original size 469, current size' "$Wc_c"
  463. rm -f _shar_wnt_.tmp
  464. fi
  465. # ============= dmake/unix/sysvr3/stdlib.h ==============
  466. if test -f 'dmake/unix/sysvr3/stdlib.h' -a X"$1" != X"-c"; then
  467.     echo 'x - skipping dmake/unix/sysvr3/stdlib.h (File already exists)'
  468.     rm -f _shar_wnt_.tmp
  469. else
  470. > _shar_wnt_.tmp
  471. sed 's/^X//' << 'SHAR_EOF' > 'dmake/unix/sysvr3/stdlib.h' &&
  472. #ifndef _STDLIB_INCLUDED_
  473. #define _STDLIB_INCLUDED_
  474. X
  475. extern /*GOTO*/ _exit();
  476. extern /*GOTO*/ exit();
  477. extern /*GOTO*/ abort();
  478. extern int system();
  479. extern char *getenv();
  480. extern char *calloc();
  481. extern char *malloc();
  482. extern char *realloc();
  483. X
  484. #ifndef _AIX
  485. /* The AIX compiler dies on illegal redefinition of free */
  486. extern free();
  487. #endif
  488. X
  489. extern int errno;
  490. X
  491. #ifndef EIO
  492. #    include <errno.h>
  493. #endif
  494. X
  495. #endif /* _STDLIB_INCLUDED_ */
  496. SHAR_EOF
  497. chmod 0640 dmake/unix/sysvr3/stdlib.h ||
  498. echo 'restore of dmake/unix/sysvr3/stdlib.h failed'
  499. Wc_c="`wc -c < 'dmake/unix/sysvr3/stdlib.h'`"
  500. test 428 -eq "$Wc_c" ||
  501.     echo 'dmake/unix/sysvr3/stdlib.h: original size 428, current size' "$Wc_c"
  502. rm -f _shar_wnt_.tmp
  503. fi
  504. # ============= dmake/unix/sysvr3/time.h ==============
  505. if test -f 'dmake/unix/sysvr3/time.h' -a X"$1" != X"-c"; then
  506.     echo 'x - skipping dmake/unix/sysvr3/time.h (File already exists)'
  507.     rm -f _shar_wnt_.tmp
  508. else
  509. > _shar_wnt_.tmp
  510. sed 's/^X//' << 'SHAR_EOF' > 'dmake/unix/sysvr3/time.h' &&
  511. /*
  512. ** Berkeley get this wrong!
  513. */
  514. #ifndef    TIME_h
  515. #define    TIME_h
  516. X
  517. typedef    long    time_t;    /* this is the thing we use */
  518. X
  519. #endif    TIME_h
  520. X
  521. SHAR_EOF
  522. chmod 0640 dmake/unix/sysvr3/time.h ||
  523. echo 'restore of dmake/unix/sysvr3/time.h failed'
  524. Wc_c="`wc -c < 'dmake/unix/sysvr3/time.h'`"
  525. test 133 -eq "$Wc_c" ||
  526.     echo 'dmake/unix/sysvr3/time.h: original size 133, current size' "$Wc_c"
  527. rm -f _shar_wnt_.tmp
  528. fi
  529. # ============= dmake/unix/sysvr4/config.h ==============
  530. if test ! -d 'dmake/unix/sysvr4'; then
  531.     mkdir 'dmake/unix/sysvr4'
  532. fi
  533. if test -f 'dmake/unix/sysvr4/config.h' -a X"$1" != X"-c"; then
  534.     echo 'x - skipping dmake/unix/sysvr4/config.h (File already exists)'
  535.     rm -f _shar_wnt_.tmp
  536. else
  537. > _shar_wnt_.tmp
  538. sed 's/^X//' << 'SHAR_EOF' > 'dmake/unix/sysvr4/config.h' &&
  539. /* RCS      -- $Header: /u2/dvadura/src/generic/dmake/src/unix/sysvr4/RCS/config.h,v 1.1 91/05/06 15:28:39 dvadura Exp $
  540. -- SYNOPSIS -- Configurarion include file.
  541. -- 
  542. -- DESCRIPTION
  543. --     There is one of these for each specific machine configuration.
  544. --    It can be used to further tweek the machine specific sources
  545. --    so that they compile.
  546. --
  547. -- AUTHOR
  548. --      Dennis Vadura, dvadura@watdragon.uwaterloo.ca
  549. --      CS DEPT, University of Waterloo, Waterloo, Ont., Canada
  550. --
  551. -- COPYRIGHT
  552. --      Copyright (c) 1990 by Dennis Vadura.  All rights reserved.
  553. -- 
  554. --      This program is free software; you can redistribute it and/or
  555. --      modify it under the terms of the GNU General Public License
  556. --      (version 1), as published by the Free Software Foundation, and
  557. --      found in the file 'LICENSE' included with this distribution.
  558. -- 
  559. --      This program is distributed in the hope that it will be useful,
  560. --      but WITHOUT ANY WARRANTY; without even the implied warrant of
  561. --      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  562. --      GNU General Public License for more details.
  563. -- 
  564. --      You should have received a copy of the GNU General Public License
  565. --      along with this program;  if not, write to the Free Software
  566. --      Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  567. --
  568. -- LOG
  569. --     $Log:    config.h,v $
  570. X * Revision 1.1  91/05/06  15:28:39  dvadura
  571. X * dmake Release Version 3.7
  572. X * 
  573. */
  574. #define _TYPES_
  575. X
  576. /* define this for configurations that don't have the coreleft function
  577. X * so that the code compiles.  To my knowledge coreleft exists only on
  578. X * Turbo C, but it is needed here since the function is used in many debug
  579. X * macros. */
  580. #define coreleft() 0L
  581. X
  582. /* Define the getcwd function that is used in the code, since BSD does
  583. X * not have getcwd, but call it getwd instead. */
  584. extern char *getcwd ANSI((char *, int));
  585. X
  586. /* Define setvbuf, SysV doesn't have one */
  587. #define setvbuf(fp, bp, type, len) setbuf( fp, NULL );
  588. X
  589. /* We don't care about CONST */
  590. #define CONST
  591. SHAR_EOF
  592. chmod 0640 dmake/unix/sysvr4/config.h ||
  593. echo 'restore of dmake/unix/sysvr4/config.h failed'
  594. Wc_c="`wc -c < 'dmake/unix/sysvr4/config.h'`"
  595. test 2015 -eq "$Wc_c" ||
  596.     echo 'dmake/unix/sysvr4/config.h: original size 2015, current size' "$Wc_c"
  597. rm -f _shar_wnt_.tmp
  598. fi
  599. # ============= dmake/unix/sysvr4/config.mk ==============
  600. if test -f 'dmake/unix/sysvr4/config.mk' -a X"$1" != X"-c"; then
  601.     echo 'x - skipping dmake/unix/sysvr4/config.mk (File already exists)'
  602.     rm -f _shar_wnt_.tmp
  603. else
  604. > _shar_wnt_.tmp
  605. sed 's/^X//' << 'SHAR_EOF' > 'dmake/unix/sysvr4/config.mk' &&
  606. # This is the SysV R4 UNIX configuration file for DMAKE
  607. #    It simply modifies the values of SRC, and checks to see if
  608. #    OSENVIRONMENT is defined.  If so it includes the appropriate
  609. #    config.mk file.
  610. #
  611. # It also sets the values of .SOURCE.c and .SOURCE.h to include the local
  612. # directory.
  613. #
  614. osrdir := $(OS)$(DIRSEPSTR)$(OSRELEASE)
  615. X
  616. # The following are required sources
  617. OSDSRC := 
  618. .IF $(OSDSRC)
  619. X   SRC    += $(OSDSRC)
  620. X   .SETDIR=$(osrdir) : $(OSDSRC)
  621. .END
  622. X
  623. .SOURCE.h : $(osrdir)
  624. X
  625. # Local configuration modifications for CFLAGS, there's local SysV includes
  626. # too.
  627. CFLAGS += -I$(osrdir)
  628. X
  629. # See if we modify anything in the lower levels.
  630. .IF $(OSENVIRONMENT) != $(NULL)
  631. X   .INCLUDE .IGNORE : $(osrdir)$(DIRSEPSTR)$(OSENVIRONMENT)$(DIRSEPSTR)config.mk
  632. .END
  633. SHAR_EOF
  634. chmod 0640 dmake/unix/sysvr4/config.mk ||
  635. echo 'restore of dmake/unix/sysvr4/config.mk failed'
  636. Wc_c="`wc -c < 'dmake/unix/sysvr4/config.mk'`"
  637. test 750 -eq "$Wc_c" ||
  638.     echo 'dmake/unix/sysvr4/config.mk: original size 750, current size' "$Wc_c"
  639. rm -f _shar_wnt_.tmp
  640. fi
  641. # ============= dmake/unix/sysvr4/make.sh ==============
  642. if test -f 'dmake/unix/sysvr4/make.sh' -a X"$1" != X"-c"; then
  643.     echo 'x - skipping dmake/unix/sysvr4/make.sh (File already exists)'
  644.     rm -f _shar_wnt_.tmp
  645. else
  646. > _shar_wnt_.tmp
  647. sed 's/^X//' << 'SHAR_EOF' > 'dmake/unix/sysvr4/make.sh' &&
  648. mkdir objects
  649. cc -c -I. -Iunix -Iunix/sysvr4 -O infer.c
  650. mv infer.o objects
  651. cc -c -I. -Iunix -Iunix/sysvr4 -O make.c
  652. mv make.o objects
  653. cc -c -I. -Iunix -Iunix/sysvr4 -O stat.c
  654. mv stat.o objects
  655. cc -c -I. -Iunix -Iunix/sysvr4 -O expand.c
  656. mv expand.o objects
  657. cc -c -I. -Iunix -Iunix/sysvr4 -O dmstring.c
  658. mv dmstring.o objects
  659. cc -c -I. -Iunix -Iunix/sysvr4 -O hash.c
  660. mv hash.o objects
  661. cc -c -I. -Iunix -Iunix/sysvr4 -O dag.c
  662. mv dag.o objects
  663. cc -c -I. -Iunix -Iunix/sysvr4 -O dmake.c
  664. mv dmake.o objects
  665. cc -c -I. -Iunix -Iunix/sysvr4 -O path.c
  666. mv path.o objects
  667. cc -c -I. -Iunix -Iunix/sysvr4 -O imacs.c
  668. mv imacs.o objects
  669. cc -c -I. -Iunix -Iunix/sysvr4 -O sysintf.c
  670. mv sysintf.o objects
  671. cc -c -I. -Iunix -Iunix/sysvr4 -O parse.c
  672. mv parse.o objects
  673. cc -c -I. -Iunix -Iunix/sysvr4 -O getinp.c
  674. mv getinp.o objects
  675. cc -c -I. -Iunix -Iunix/sysvr4 -O quit.c
  676. mv quit.o objects
  677. cc -c -I. -Iunix -Iunix/sysvr4 -O state.c
  678. mv state.o objects
  679. cc -c -I. -Iunix -Iunix/sysvr4 -O basename.c
  680. mv basename.o objects
  681. cc -c -I. -Iunix -Iunix/sysvr4 -O dmdump.c
  682. mv dmdump.o objects
  683. cc -c -I. -Iunix -Iunix/sysvr4 -O macparse.c
  684. mv macparse.o objects
  685. cc -c -I. -Iunix -Iunix/sysvr4 -O rulparse.c
  686. mv rulparse.o objects
  687. cc -c -I. -Iunix -Iunix/sysvr4 -O percent.c
  688. mv percent.o objects
  689. cc -c -I. -Iunix -Iunix/sysvr4 -O function.c
  690. mv function.o objects
  691. cc -c -I. -Iunix -Iunix/sysvr4 -O unix/arlib.c
  692. mv arlib.o objects
  693. cc -c -I. -Iunix -Iunix/sysvr4 -O unix/dirbrk.c
  694. mv dirbrk.o objects
  695. cc -c -I. -Iunix -Iunix/sysvr4 -O unix/rmprq.c
  696. mv rmprq.o objects
  697. cc -c -I. -Iunix -Iunix/sysvr4 -O unix/ruletab.c
  698. mv ruletab.o objects
  699. cc -c -I. -Iunix -Iunix/sysvr4 -O unix/runargv.c
  700. mv runargv.o objects
  701. cc  -o dmake  objects/infer.o objects/make.o objects/stat.o objects/expand.o objects/dmstring.o objects/hash.o objects/dag.o objects/dmake.o objects/path.o objects/imacs.o objects/sysintf.o objects/parse.o objects/getinp.o objects/quit.o objects/state.o objects/basename.o objects/dmdump.o objects/macparse.o objects/rulparse.o objects/percent.o objects/function.o objects/arlib.o objects/dirbrk.o objects/rmprq.o objects/ruletab.o objects/runargv.o 
  702. cp unix/sysvr4/startup.mk startup.mk
  703. SHAR_EOF
  704. chmod 0640 dmake/unix/sysvr4/make.sh ||
  705. echo 'restore of dmake/unix/sysvr4/make.sh failed'
  706. Wc_c="`wc -c < 'dmake/unix/sysvr4/make.sh'`"
  707. test 2153 -eq "$Wc_c" ||
  708.     echo 'dmake/unix/sysvr4/make.sh: original size 2153, current size' "$Wc_c"
  709. rm -f _shar_wnt_.tmp
  710. fi
  711. # ============= dmake/unix/sysvr4/public.h ==============
  712. if test -f 'dmake/unix/sysvr4/public.h' -a X"$1" != X"-c"; then
  713.     echo 'x - skipping dmake/unix/sysvr4/public.h (File already exists)'
  714.     rm -f _shar_wnt_.tmp
  715. else
  716. > _shar_wnt_.tmp
  717. sed 's/^X//' << 'SHAR_EOF' > 'dmake/unix/sysvr4/public.h' &&
  718. /* RCS      -- $Header: /u2/dvadura/src/generic/dmake/src/unix/sysvr4/RCS/public.h,v 1.1 91/05/06 15:28:41 dvadura Exp Locker: dvadura $
  719. -- WARNING  -- This file is AUTOMATICALLY GENERATED DO NOT EDIT IT
  720. --
  721. -- SYNOPSIS -- Local functions exported to be visible by others.
  722. --
  723. -- DESCRIPTION
  724. --      This file is generated by 'genpub'.  Function declarations
  725. --      that appear in this file are extracted by 'genpub' from
  726. --      source files.  Any function in the source file whose definition
  727. --      appears like:
  728. --
  729. --          PUBLIC return_type
  730. --          function( arg_list );
  731. --          type_expr1 arg1;
  732. --          ...
  733. --
  734. --      has its definition extracted and a line of the form:
  735. --
  736. --          return_type function ANSI((type_expr1,type_expr2,...));
  737. --
  738. --      entered into the output file.
  739. --
  740. -- AUTHOR
  741. --      Dennis Vadura, dvadura@watdragon.uwaterloo.ca
  742. --      CS DEPT, University of Waterloo, Waterloo, Ont., Canada
  743. --
  744. -- COPYRIGHT
  745. --      Copyright (c) 1990 by Dennis Vadura.  All rights reserved.
  746. -- 
  747. --      This program is free software; you can redistribute it and/or
  748. --      modify it under the terms of the GNU General Public License
  749. --      (version 1), as published by the Free Software Foundation, and
  750. --      found in the file 'LICENSE' included with this distribution.
  751. -- 
  752. --      This program is distributed in the hope that it will be useful,
  753. --      but WITHOUT ANY WARRANTY; without even the implied warrant of
  754. --      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  755. --      GNU General Public License for more details.
  756. -- 
  757. --      You should have received a copy of the GNU General Public License
  758. --      along with this program;  if not, write to the Free Software
  759. --      Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  760. --
  761. -- LOG
  762. --     $Log:    public.h,v $
  763. X * Revision 1.1  91/05/06  15:28:41  dvadura
  764. X * dmake Release Version 3.7
  765. X * 
  766. */
  767. X
  768. #ifndef _DMAKE_PUBLIC_h
  769. #define _DMAKE_PUBLIC_h
  770. X
  771. void Infer_recipe ANSI((CELLPTR, CELLPTR));
  772. int Make_targets ANSI(());
  773. int Exec_commands ANSI((CELLPTR));
  774. void Pop_dir ANSI((int));
  775. void Append_line ANSI((char *, int, FILE *, char *, int, int));
  776. void Stat_target ANSI((CELLPTR, int));
  777. char * Expand ANSI((char *));
  778. char * Apply_edit ANSI((char *, char *, char *, int, int));
  779. void Map_esc ANSI((char *));
  780. char* Apply_modifiers ANSI((int, char *));
  781. char* Tokenize ANSI((char *, char *));
  782. char * _strjoin ANSI((char *, char *, int, int));
  783. char * _stradd ANSI((char *, char *, int));
  784. char * _strapp ANSI((char *, char *));
  785. char * _strdup ANSI((char *));
  786. char * _strpbrk ANSI((char *, char *));
  787. char * _strspn ANSI((char *, char *));
  788. char * _strstr ANSI((char *, char *));
  789. char * _substr ANSI((char *, char *));
  790. uint16 Hash ANSI((char *, uint32 *));
  791. HASHPTR Get_name ANSI((char *, HASHPTR *, int));
  792. HASHPTR Search_table ANSI((HASHPTR *, char *, uint16 *, uint32 *));
  793. HASHPTR Def_macro ANSI((char *, char *, int));
  794. CELLPTR Def_cell ANSI((char *));
  795. LINKPTR Add_prerequisite ANSI((CELLPTR, CELLPTR, int, int));
  796. void Clear_prerequisites ANSI((CELLPTR));
  797. int Test_circle ANSI((CELLPTR, int));
  798. STRINGPTR Def_recipe ANSI((char *, STRINGPTR, int, int));
  799. t_attr Rcp_attribute ANSI((char *));
  800. int main ANSI((int, char **));
  801. FILE * Openfile ANSI((char *, int, int));
  802. FILE * Closefile ANSI(());
  803. FILE * Search_file ANSI((char *, char **));
  804. char * Filename ANSI(());
  805. void No_ram ANSI(());
  806. int Usage ANSI((int));
  807. int Version ANSI(());
  808. char * Get_suffix ANSI((char *));
  809. char * Build_path ANSI((char *, char *));
  810. void Make_rules ANSI(());
  811. void Create_macro_vars ANSI(());
  812. time_t Do_stat ANSI((char *, char *, char **));
  813. int Do_touch ANSI((char *, char *, char **));
  814. void Void_lib_cache ANSI((char *, char *));
  815. time_t Do_time ANSI(());
  816. int Do_cmnd ANSI((char *, int, int, CELLPTR, int, int, int));
  817. char ** Pack_argv ANSI((int, int, char *));
  818. char * Read_env_string ANSI((char *));
  819. int Write_env_string ANSI((char *, char *));
  820. void ReadEnvironment ANSI(());
  821. void Catch_signals ANSI((void (*)()));
  822. void Clear_signals ANSI(());
  823. void Prolog ANSI((int, char* []));
  824. void Epilog ANSI((int));
  825. char * Get_current_dir ANSI(());
  826. int Set_dir ANSI((char*));
  827. char Get_switch_char ANSI(());
  828. FILE* Get_temp ANSI((char **, char *, int));
  829. FILE * Start_temp ANSI((char *, CELLPTR, char **));
  830. void Open_temp_error ANSI((char *, char *));
  831. void Link_temp ANSI((CELLPTR, FILE *, char *));
  832. void Close_temp ANSI((CELLPTR, FILE *));
  833. void Unlink_temp_files ANSI((CELLPTR));
  834. void Handle_result ANSI((int, int, int, CELLPTR));
  835. void Update_time_stamp ANSI((CELLPTR));
  836. void Parse ANSI((FILE *));
  837. int Get_line ANSI((char *, FILE *));
  838. char * Do_comment ANSI((char *, char **, int));
  839. char * Get_token ANSI((TKSTRPTR, char *, int));
  840. void Quit ANSI(());
  841. void Read_state ANSI(());
  842. void Write_state ANSI(());
  843. int Check_state ANSI((CELLPTR, STRINGPTR *, int));
  844. char* basename ANSI((char *));
  845. void Dump ANSI(());
  846. void Dump_recipe ANSI((STRINGPTR));
  847. int Parse_macro ANSI((char *, int));
  848. int Macro_op ANSI((char *));
  849. int Parse_rule_def ANSI((int *));
  850. int Rule_op ANSI((char *));
  851. void Add_recipe_to_list ANSI((char *, int, int));
  852. void Bind_rules_to_targets ANSI((int));
  853. int Set_group_attributes ANSI((char *));
  854. DFALINKPTR Match_dfa ANSI((char *));
  855. void Check_circle_dfa ANSI(());
  856. void Add_nfa ANSI((char *));
  857. char * Exec_function ANSI((char *));
  858. time_t seek_arch ANSI((char *, char *));
  859. int If_root_path ANSI((char *));
  860. void Remove_prq ANSI((CELLPTR));
  861. int runargv ANSI((CELLPTR, int, int, int, int, char *));
  862. int Wait_for_child ANSI((int, int));
  863. void Clean_up_processes ANSI(());
  864. X
  865. #endif
  866. SHAR_EOF
  867. chmod 0640 dmake/unix/sysvr4/public.h ||
  868. echo 'restore of dmake/unix/sysvr4/public.h failed'
  869. Wc_c="`wc -c < 'dmake/unix/sysvr4/public.h'`"
  870. test 5522 -eq "$Wc_c" ||
  871.     echo 'dmake/unix/sysvr4/public.h: original size 5522, current size' "$Wc_c"
  872. rm -f _shar_wnt_.tmp
  873. fi
  874. # ============= dmake/unix/sysvr4/startup.mk ==============
  875. if test -f 'dmake/unix/sysvr4/startup.mk' -a X"$1" != X"-c"; then
  876.     echo 'x - skipping dmake/unix/sysvr4/startup.mk (File already exists)'
  877.     rm -f _shar_wnt_.tmp
  878. else
  879. > _shar_wnt_.tmp
  880. sed 's/^X//' << 'SHAR_EOF' > 'dmake/unix/sysvr4/startup.mk' &&
  881. # Generic UNIX DMAKE startup file.  Customize to suit your needs.
  882. # Should work for both SYSV, and BSD 4.3
  883. # See the documentation for a description of internally defined macros.
  884. #
  885. # Disable warnings for macros redefined here that were given
  886. # on the command line.
  887. __.SILENT := $(.SILENT)
  888. .SILENT   := yes
  889. X
  890. # Configuration parameters for DMAKE startup.mk file
  891. # Set these to NON-NULL if you wish to turn the parameter on.
  892. _HAVE_RCS    := yes        # yes => RCS  is installed.
  893. _HAVE_SCCS    := yes        # yes => SCCS is installed.
  894. X
  895. # Applicable suffix definitions
  896. A := .a        # Libraries
  897. E :=        # Executables
  898. F := .f        # Fortran
  899. O := .o        # Objects
  900. P := .p        # Pascal
  901. S := .s        # Assembler sources
  902. V := ,v        # RCS suffix
  903. X
  904. # Recipe execution configurations
  905. SHELL        := /bin/sh
  906. SHELLFLAGS    := -ce
  907. GROUPSHELL    := $(SHELL)
  908. GROUPFLAGS    := 
  909. SHELLMETAS    := |();&<>?*][$$:\\#`'"
  910. GROUPSUFFIX    :=
  911. X
  912. # Standard C-language command names and flags
  913. X   CPP       := /lib/cpp        # C-preprocessor
  914. X   CC      := cc        # C-compiler and flags
  915. X   CFLAGS   =
  916. X
  917. X   AS      := as        # Assembler and flags
  918. X   ASFLAGS  = 
  919. X
  920. X   LD       = $(CC)        # Loader and flags
  921. X   LDFLAGS  =
  922. X   LDLIBS   =
  923. X
  924. # Definition of $(MAKE) macro for recursive makes.
  925. X   MAKE = $(MAKECMD) $(MFLAGS)
  926. X
  927. # Definition of Print command for this system.
  928. X   PRINT = lpr
  929. X
  930. # Language and Parser generation Tools and their flags
  931. X   YACC      := yacc        # standard yacc
  932. X   YFLAGS  =
  933. X   YTAB      := y.tab        # yacc output files name stem.
  934. X
  935. X   LEX      := lex        # standard lex
  936. X   LFLAGS  =
  937. X   LEXYY  := lex.yy        # lex output file
  938. X
  939. # Other Compilers, Tools and their flags
  940. X   PC    := pc            # pascal compiler
  941. X   RC    := f77            # ratfor compiler
  942. X   FC    := f77            # fortran compiler
  943. X
  944. X   CO       := co        # check out for RCS
  945. X   COFLAGS := -q
  946. X
  947. X   AR     := ar            # archiver
  948. X   ARFLAGS = ruv
  949. X
  950. X   RM       := /bin/rm        # remove a file command
  951. X   RMFLAGS  =
  952. X
  953. # Implicit generation rules for making inferences.
  954. # We don't provide .yr or .ye rules here.  They're obsolete.
  955. # Rules for making *$O
  956. X   %$O : %.c ; $(CC) $(CFLAGS) -c $<
  957. X   %$O : %$P ; $(PC) $(PFLAGS) -c $<
  958. X   %$O : %$S ; $(AS) $<
  959. X   %$O : %.cl ; class -c $<
  960. X   %$O : %.e %.r %.F %$F
  961. X    $(FC) $(RFLAGS) $(EFLAGS) $(FFLAGS) -c $<
  962. X
  963. # Executables
  964. X   %$E : %$O ; $(LD) $(LDFLAGS) -o $@ $< $(LDLIBES)
  965. X
  966. # lex and yacc rules
  967. X   %.c : %.y ; $(YACC)  $(YFLAGS) $<; mv $(YTAB).c $@
  968. X   %.c : %.l ; $(LEX)   $(LFLAGS) $<; mv $(LEXYY).c $@
  969. X
  970. # This rule tells how to make *.out from it's immediate list of prerequisites
  971. # UNIX only.
  972. X   %.out :; $(LD) $(LDFLAGS) -o $@ $^ $(LDLIBS)
  973. X
  974. # RCS support
  975. .IF $(_HAVE_RCS)
  976. X   % : %$V $$(@:d)RCS/$$(@:f)$V;- $(CO) $(COFLAGS) $@
  977. X   .NOINFER : %$V $$(@:d)RCS/$$(@:f)$V
  978. .END
  979. X
  980. # SCCS support
  981. .IF $(_HAVE_SCCS)
  982. X   % : s.% ; get $@
  983. X   .NOINFER : s.%
  984. .END
  985. X
  986. # Recipe to make archive files.
  987. %$A :
  988. [
  989. X   $(AR) $(ARFLAGS) $@ $?
  990. X   $(RM) $(RMFLAGS) $?
  991. X   ranlib $@
  992. ]
  993. X
  994. # DMAKE uses this recipe to remove intermediate targets
  995. .REMOVE :; $(RM) -f $<
  996. X
  997. # AUGMAKE extensions for SYSV compatibility
  998. @B = $(@:b)
  999. @D = $(@:d)
  1000. @F = $(@:f)
  1001. *B = $(*:b)
  1002. *D = $(*:d)
  1003. *F = $(*:f)
  1004. <B = $(<:b)
  1005. <D = $(<:d)
  1006. <F = $(<:f)
  1007. ?B = $(?:b)
  1008. ?F = $(?:f)
  1009. ?D = $(?:d)
  1010. X
  1011. # Turn warnings back to previous setting.
  1012. .SILENT := $(__.SILENT)
  1013. X
  1014. # Local startup file if any
  1015. .INCLUDE .IGNORE: "_startup.mk"
  1016. SHAR_EOF
  1017. chmod 0640 dmake/unix/sysvr4/startup.mk ||
  1018. echo 'restore of dmake/unix/sysvr4/startup.mk failed'
  1019. Wc_c="`wc -c < 'dmake/unix/sysvr4/startup.mk'`"
  1020. test 3187 -eq "$Wc_c" ||
  1021.     echo 'dmake/unix/sysvr4/startup.mk: original size 3187, current size' "$Wc_c"
  1022. rm -f _shar_wnt_.tmp
  1023. fi
  1024. # ============= dmake/unix/sysvr4/stdarg.h ==============
  1025. if test -f 'dmake/unix/sysvr4/stdarg.h' -a X"$1" != X"-c"; then
  1026.     echo 'x - skipping dmake/unix/sysvr4/stdarg.h (File already exists)'
  1027.     rm -f _shar_wnt_.tmp
  1028. else
  1029. > _shar_wnt_.tmp
  1030. sed 's/^X//' << 'SHAR_EOF' > 'dmake/unix/sysvr4/stdarg.h' &&
  1031. /* Some V.4 systems aren't ansi, just to make matters ugly.
  1032. X   If the dmake sources used another name for this include file,
  1033. X   then this wouldn't be quite so awful. */
  1034. #ifdef __STDC__
  1035. #include "/usr/include/stdarg.h"
  1036. #else
  1037. /*
  1038. X * stdarg.h
  1039. X *
  1040. X * defines ANSI style macros for accessing arguments of a function which takes
  1041. X * a variable number of arguments
  1042. X *
  1043. X */
  1044. X
  1045. typedef char *va_list;
  1046. X
  1047. #if defined(sparc)
  1048. # define va_alist __builtin_va_alist
  1049. #endif
  1050. # define va_dcl int va_alist
  1051. # define va_start(list,v) list = (char *)&va_alist
  1052. # define va_end(list)     list = NULL
  1053. #if defined(mips)
  1054. #define va_arg(list, mode) ((mode *)(list = \
  1055. X    (char *) (sizeof(mode) > 4 ? ((int)list + 2*8 - 1) & -8 \
  1056. X                   : ((int)list + 2*4 - 1) & -4)))[-1]
  1057. #else
  1058. # define va_arg(list,mode) ((mode *)(list += sizeof(mode)))[-1]
  1059. #endif
  1060. #endif
  1061. X
  1062. SHAR_EOF
  1063. chmod 0640 dmake/unix/sysvr4/stdarg.h ||
  1064. echo 'restore of dmake/unix/sysvr4/stdarg.h failed'
  1065. Wc_c="`wc -c < 'dmake/unix/sysvr4/stdarg.h'`"
  1066. test 819 -eq "$Wc_c" ||
  1067.     echo 'dmake/unix/sysvr4/stdarg.h: original size 819, current size' "$Wc_c"
  1068. rm -f _shar_wnt_.tmp
  1069. fi
  1070. # ============= dmake/version.h ==============
  1071. if test -f 'dmake/version.h' -a X"$1" != X"-c"; then
  1072.     echo 'x - skipping dmake/version.h (File already exists)'
  1073.     rm -f _shar_wnt_.tmp
  1074. else
  1075. > _shar_wnt_.tmp
  1076. sed 's/^X//' << 'SHAR_EOF' > 'dmake/version.h' &&
  1077. /* dmake version number.  */
  1078. X
  1079. #define VERSION "3.70"
  1080. SHAR_EOF
  1081. chmod 0640 dmake/version.h ||
  1082. echo 'restore of dmake/version.h failed'
  1083. Wc_c="`wc -c < 'dmake/version.h'`"
  1084. test 53 -eq "$Wc_c" ||
  1085.     echo 'dmake/version.h: original size 53, current size' "$Wc_c"
  1086. rm -f _shar_wnt_.tmp
  1087. fi
  1088. # ============= dmake/vextern.h ==============
  1089. if test -f 'dmake/vextern.h' -a X"$1" != X"-c"; then
  1090.     echo 'x - skipping dmake/vextern.h (File already exists)'
  1091.     rm -f _shar_wnt_.tmp
  1092. else
  1093. > _shar_wnt_.tmp
  1094. sed 's/^X//' << 'SHAR_EOF' > 'dmake/vextern.h' &&
  1095. /* RCS      -- $Header: /u2/dvadura/src/generic/dmake/src/RCS/vextern.h,v 1.1 91/05/06 15:23:39 dvadura Exp $
  1096. -- SYNOPSIS -- global variable declarations.
  1097. -- 
  1098. -- DESCRIPTION
  1099. --     Leave _DEFINE_GLOBALS_ undefined and the following declarations
  1100. --    will be defined as global variables, otherwise you get the
  1101. --    external declarations to the same global variables.
  1102. --
  1103. -- AUTHOR
  1104. --      Dennis Vadura, dvadura@watdragon.uwaterloo.ca
  1105. --      CS DEPT, University of Waterloo, Waterloo, Ont., Canada
  1106. --
  1107. -- COPYRIGHT
  1108. --      Copyright (c) 1990 by Dennis Vadura.  All rights reserved.
  1109. -- 
  1110. --      This program is free software; you can redistribute it and/or
  1111. --      modify it under the terms of the GNU General Public License
  1112. --      (version 1), as published by the Free Software Foundation, and
  1113. --      found in the file 'LICENSE' included with this distribution.
  1114. -- 
  1115. --      This program is distributed in the hope that it will be useful,
  1116. --      but WITHOUT ANY WARRANTY; without even the implied warrant of
  1117. --      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  1118. --      GNU General Public License for more details.
  1119. -- 
  1120. --      You should have received a copy of the GNU General Public License
  1121. --      along with this program;  if not, write to the Free Software
  1122. --      Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  1123. --
  1124. -- LOG
  1125. --     $Log:    vextern.h,v $
  1126. X * Revision 1.1  91/05/06  15:23:39  dvadura
  1127. X * dmake Release Version 3.7
  1128. X * 
  1129. */
  1130. X
  1131. /* These two are defined in dir/ruletab.c and dir/dirbrk.c, and are always
  1132. X * imported as externals by the other code.  Their defining modules do not
  1133. X * #include this file. */
  1134. extern    char*    DirBrkStr;    /* pointer to value of macro DIRBRKSTR    */
  1135. extern    char**    Rule_tab;    /* Builtin rules */
  1136. X
  1137. #ifndef _DEFINE_GLOBALS_
  1138. #define EXTERN    extern
  1139. #else
  1140. #define EXTERN
  1141. #endif
  1142. X
  1143. EXTERN    int    Line_number;    /* Current line number in make file parse */
  1144. EXTERN    t_attr    Glob_attr;    /* Global attrs to control global ops     */
  1145. EXTERN    char*    Prep;        /* Value of macro PREP              */
  1146. EXTERN    char*    Makedir;    /* pointer to macro value for MAKEDIR     */
  1147. EXTERN    char*     Start_dir;    /* cell for   macro value for .SETDIR      */
  1148. EXTERN    char*    Shell;        /* pointer to macro value for SHELL       */
  1149. EXTERN    char*    Shell_flags;    /* pointer to macro value for SHELLFLAGS  */
  1150. EXTERN    char*    GShell;        /* pointer to macro value for GROUPSHELL  */
  1151. EXTERN    char*    GShell_flags;    /* pointer to macro value for GROUPFLAGS  */
  1152. EXTERN    char*    Shell_metas;    /* pointer to macro value for SHELLMETAS  */
  1153. EXTERN    char*    Grp_suff;    /* pointer to macro value for GROUPSUFFIX */
  1154. EXTERN  char*   DirSepStr;    /* pointer to macro value for DIRSEPSTR   */
  1155. EXTERN    char*    Pname;        /* dmake process invoke name              */
  1156. EXTERN    char*    Pwd;        /* current working dir, value of PWD      */
  1157. EXTERN    char*    Tmd;        /* path to directory where dmake started  */
  1158. EXTERN    char*    Keep_state;    /* current .KEEP_STATE file          */
  1159. EXTERN    int    Target;        /* TRUE if target found in makefile       */
  1160. EXTERN    int    If_expand;    /* TRUE if calling Expand from getinp.c   */
  1161. EXTERN  int    If_multi;    /* M_MULTI for expand of single MULTI macs*/
  1162. EXTERN  int    Suppress_temp_file;/* TRUE if doing a test in _exec_recipe   */
  1163. EXTERN    int    Readenv;    /* TRUE if defining macro from environment*/
  1164. EXTERN    int    Makemkf;    /* TRUE if making makefile(s)          */
  1165. EXTERN    int    Nest_level;    /* Nesting level for .IF .ELSE .END ...   */
  1166. EXTERN    int    Def_targets;    /* TRUE if defining targets          */
  1167. X
  1168. EXTERN  CELLPTR Root;        /* Root of the make graph          */
  1169. X
  1170. EXTERN  CELLPTR Current_target; /* cell of current target being made      */
  1171. EXTERN  int    Wait_for_completion;
  1172. EXTERN  int    Doing_bang;
  1173. EXTERN  int    Packed_shell;    /* TRUE if packed args to use a shell      */
  1174. EXTERN  int    Swap_on_exec;    /* TRUE if going to swap on exec call     */
  1175. EXTERN  int    State;        /* parser state                  */
  1176. EXTERN  int    Group;        /* parsing a group recipe ==> TRUE        */
  1177. X
  1178. /* Command line option flags are defined here.  They correspond one-for one
  1179. X * with the flags defined in dmake.c */
  1180. EXTERN    char    *Augmake;    /* -A */
  1181. EXTERN  char    Comment;    /* -c */
  1182. EXTERN    char    Get_env;    /* -e or -E */
  1183. EXTERN    int    Continue;    /* -k */
  1184. EXTERN    int    Force;        /* -u */
  1185. EXTERN    int    Listing;    /* -p */
  1186. EXTERN    int    Rules;        /* -r */
  1187. EXTERN    int    Trace;        /* -n */
  1188. EXTERN    int    Touch;        /* -t */
  1189. EXTERN    int    Check;        /* -q */
  1190. EXTERN    uint16    Verbose;    /* -v */
  1191. EXTERN    int    Microsoft;    /* -M */
  1192. EXTERN    int    Transitive;    /* -T */
  1193. X
  1194. EXTERN    HASHPTR    Macs[HASH_TABLE_SIZE];    /* hash table for macro defs    */
  1195. EXTERN    HASHPTR    Defs[HASH_TABLE_SIZE];    /* hash table for other defs    */
  1196. X
  1197. EXTERN    char    *Buffer;        /* a general purpose buffer     */
  1198. EXTERN  int    Buffer_size;
  1199. EXTERN  int    Max_proclmt;        /* limit of max # of conc procs */
  1200. EXTERN    int    Max_proc;        /* max # of conc procs        */
  1201. SHAR_EOF
  1202. chmod 0640 dmake/vextern.h ||
  1203. echo 'restore of dmake/vextern.h failed'
  1204. Wc_c="`wc -c < 'dmake/vextern.h'`"
  1205. test 4702 -eq "$Wc_c" ||
  1206.     echo 'dmake/vextern.h: original size 4702, current size' "$Wc_c"
  1207. rm -f _shar_wnt_.tmp
  1208. fi
  1209. # ============= dmake/LICENSE ==============
  1210. if test -f 'dmake/LICENSE' -a X"$1" != X"-c"; then
  1211.     echo 'x - skipping dmake/LICENSE (File already exists)'
  1212.     rm -f _shar_wnt_.tmp
  1213. else
  1214. > _shar_wnt_.tmp
  1215. sed 's/^X//' << 'SHAR_EOF' > 'dmake/LICENSE' &&
  1216. X            GNU GENERAL PUBLIC LICENSE
  1217. SHAR_EOF
  1218. true || echo 'restore of dmake/LICENSE failed'
  1219. fi
  1220. echo 'End of part 36, continue with part 37'
  1221. echo 37 > _shar_seq_.tmp
  1222. exit 0
  1223.  
  1224. exit 0 # Just in case...
  1225. -- 
  1226. Kent Landfield                   INTERNET: kent@sparky.IMD.Sterling.COM
  1227. Sterling Software, IMD           UUCP:     uunet!sparky!kent
  1228. Phone:    (402) 291-8300         FAX:      (402) 291-4362
  1229. Please send comp.sources.misc-related mail to kent@uunet.uu.net.
  1230.